package com.yyh.photo.common;

import lombok.Data;

import java.io.Serializable;

@Data
public class BaseEntity implements Serializable {

    /**
     *
     */
    private static final long serialVersionUID = 1L;
    private Integer pageNum;
    private Integer pageSize;
    private String sort;// 排序字段名
    private String order;// 按什么排序(asc,desc)
    private String dbType;
    public Integer getPageNum() {
        if(pageNum == null ){
            return 1;
        }
        return pageNum;
    }

    public void setPageNum(Integer pageNum) {
        this.pageNum = pageNum;
    }

    public Integer getPageSize() {
        if(pageSize == null ){
            return 10;
        }
        return pageSize;
    }

    public void setPageSize(Integer pageSize) {
        this.pageSize = pageSize;
    }
}
